Skip to content

More updates for DI types philosophy #7916

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed

More updates for DI types philosophy #7916

wants to merge 2 commits into from

Conversation

weaverryan
Copy link
Member

Hi guys!

This is another big (sorry) PR for updating things for using type-hinting for injection. I only have a few directories remaining to review!

FYI, the following directories I'm not planning on reviewing, at least not right away (so, these are up for grabs!)

  • best_practices
  • bundles
  • components
  • console
  • create_framework
  • reference

Thanks!

Copy link
Member

@javiereguiluz javiereguiluz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 Ryan, thanks for another great PR. And you removed double the lines that you changed/added, so this is fantastic!

</services>
</container>
<config>
<firewall name="main">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This cde uses 2-white space indentation. Should it be changed to 4?


$container->loadFromExtension('security', array(
'providers' => array(
'api_key_user_provider' => array(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are two white spaces before the arrow operator here -> 'api_key_user_provider' => array(

@@ -682,65 +594,12 @@ current URL is before creating the token in ``createToken()``::
// set the only URL where we should look for auth information
// and only return the token if we're at that URL
$targetUrl = '/login/check';
if (!$this->httpUtils->checkRequestPath($request, $targetUrl)) {
if ($request->getPathInfo() != $targetUrl)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use a strict checking here and replace != by !==?

What makes private services special is that, since the container knows that the
service will never be requested from outside, it can optimize whether and how it
is instanciated. This increases the container's performance.
Private services are special because it allows the container to optimize whether
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

because it allows the container [...] -> because they allow the container [...] ?

@weaverryan
Copy link
Member Author

And you removed double the lines that you changed/added, so this is fantastic!

I didn't even realize! That's GREAT!

Thanks for the review - I know these are a pain, but you're helping me continue to move quickly and get this done. Merged this into the 3.3 branch

@weaverryan weaverryan deleted the final-types branch May 18, 2017 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants